<template>
  <el-dialog v-bind="$attrs" title="评估详情" min-h-200>
    <PlusTable mb-20 :columns="tableConfig" :data="data" />
  </el-dialog>
</template>

<script setup lang="ts">
import type { PlusColumn, PlusTable } from '@wlydfe/pro-ui'
import type { WaybillLoanRiskDetailModel } from '@/api/type'

defineProps({
  data: {
    type: Array as PropType<WaybillLoanRiskDetailModel[]>,
    default: () => [],
  },
})

const tableConfig: PlusColumn[] = [
  {
    label: '风险提示分类',
    prop: 'riskWarningCategory',
    width: 140,
  },
  {
    label: '风险提示内容',
    prop: 'riskWarningContent',
  },
  {
    label: '风险等级',
    prop: 'riskLevel',
    valueType: 'select',
    width: 140,
    options: riskDetailLevelOptions,
  },
]
</script>
